<?php
// +--------------------------------------------------------------------------------------------------------------------
// | Author: Admin <543423@qq.com>
// +--------------------------------------------------------------------------------------------------------------------
// | Copyright ThinkAdmin http://www.thinkadmin.cn All rights reserved.
// +---------------------------------------------------------------------------------------------------------------------

/**
 * +---------------------------------------------------------------------------------------------------------------------
 * | 项目入口文件
 * +---------------------------------------------------------------------------------------------------------------------
 *  ·本程序需要PHP5.3.0及以上版本运行
 *  ·强烈建议将Noweb目录部署到非web目录,部署只需修改NOWEB_PATH常量路径即可
 *  ·部署模式请关闭调试模式 define('APP_DEBUG', false)
 * +---------------------------------------------------------------------------------------------------------------------
 */

//检测PHP环境
if(version_compare(PHP_VERSION, '5.3.0','<')) die ('require PHP > 5.3.0!');	

//定义Noweb目录路径
define('NOWEB_PATH', __DIR__.'/Noweb/');

// 是否调试模式
define('APP_DEBUG', true); 

//定义项目运行缓存目录
define('RUNTIME_PATH', NOWEB_PATH . 'Write/Runtime/');

//定义日志记录目录
define('LOG_PATH',  NOWEB_PATH . 'Write/Logs/');

//定义静态缓存目录
define('HTML_PATH', RUNTIME_PATH . 'Html/');

//定义项目公共模块目录
define('COMMON_PATH', NOWEB_PATH . 'Nowrite/Common/');

//定义项目目录路径
define('APP_PATH', NOWEB_PATH . 'Nowrite/Modules/');

//关闭生成安全文件
define('BUILD_DIR_SECURE', false);

//加载Thinkphp框架核心
require NOWEB_PATH . 'Nowrite/ThinkPHP/ThinkPHP.php';